package rendava;

import java.awt.FontMetrics;
import java.awt.Graphics;
/**
 * Contains the rendering information for the <hr> class.
 * @author Ben Gomm
 * @version 0.9
 *
 */
public class HorizontalLine extends SimpleTag{
	
	
	public void renderInfo(Renderer renderer)
	{
		FontMetrics fm = renderer.getCanvas().getGraphics().getFontMetrics();
		int stringHeight = fm.getHeight();
		Graphics g = renderer.getGraphics();
		renderer.setY(renderer.getY()+stringHeight);
		renderer.setX(0);
		g.drawLine(renderer.getX(), renderer.getY(), renderer.getCanvasWidth(), renderer.getY());
		renderer.setY(renderer.getY()+stringHeight);
		renderer.setX(0);
	}
		
	public String closeTag()
	{
		return "close";
	}


}